The Advanced Calendar Component > FAdvancedCalendar.setCellStyle(style, dateObj)

 

FAdvancedCalendar.setCellStyle(style, dateObj)

Availability

Flash Player 6.

Usage

myCalendar.setCellStyle(style, dateObj);

Parameters

style
An object with the following properties defining the style of the cell:
   background
   border
   textStyle
   selectedBackground
   selectedBorder
   selectedTextStyle

dateObj
A Date object specifying the date that the style should be applied to.

Returns

Nothing.

Description

Adds a user defined cell style object to a calendar day.

Example

The following example will set the default style for any cell that has data asscociated with it. This is an easy way to give the user an indication that there is something associated with the given date.

var style = {
    background: 0xFFFFFF,
    border: 0xFFFFFF,
    textStyle: new TextFormat(null,null,0xFFFFFF),
    selectedBackground: 0xCCCCCC,
    selectedBorder: 0xFFFFFF,
    selectedTextStyle: new TextFormat(null,null,0x000000)
};
myCalendar.setCellStyle(style);

See also

FAdvancedCalendar.getCellStyle